package com.itheima.service.impl;

import com.itheima.dao.FileSortMapper;
import com.itheima.service.FileSortService;
import com.itheima.pojo.FileSort;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class FileSortServiceImpl implements FileSortService {

    @Autowired
    private FileSortMapper fileSortMapper;

    /**
     * 根据类名查询uid
     * @param sortName
     * @return
     */
    @Override
    public String getUidByFileSortName(String sortName) {
        return fileSortMapper.getUidByFileSortName(sortName);
    }

    /**
     * 根据类名查询url
     * @param sortName
     * @return
     */
    @Override
    public FileSort getByFileSortName(String sortName) {
        return fileSortMapper.getUrlByFileSortName(sortName);
    }
}
